import request from '@/utils/request'

export function getUserInfo(token) {
  const data = {
    token
  }
  return request({
    url: '/user/info',
    data
  })
}
export function getAuthInfo(data) {
  return request({
    url: '/weixin/login',
    data
  })
}
export function getUserDetail(data) {
  return request({
    url: '/weixin/user/detail',
    data
  })
}

export function saveUserDetail(data) {
  return request({
    url: '/weixin/user/saveDetail',
    data
  })
}
export function saveHeadImg(data) {
    return request({
        url: '/weixin/user/saveHeadImg',
        data
    })
}
export function savePhone(data) {
    return request({
        url: '/weixin/user/savePhone',
        data
    })
}
export function savePassword(data) {
    return request({
        url: '/weixin/user/savePassword',
        data
    })
}
export function getBookList(data) {
    return request({
        url: '/weixin/user/bookList',
        data
    })
}
export function getHistoryList(data) {
    return request({
        url: '/weixin/user/heardHistory',
        data
    })
}
export function getClassifyList(data) {
    return request({
        url: '/weixin/user/classifyList',
        data
    })
}
export function saveClassifyList(data) {
    return request({
        url: '/weixin/user/saveClassifyList',
        data
    })
}
export function saveOpinion(data) {
    return request({
        url: '/weixin/user/saveOpinion',
        data
    })
}